64b8ff5f9f9ab3031ca10dd9651849921e49eb5f,domain/src/test/java/org/jboss/as/model/base/ProfileElementTestBase.java,ProfileElementTestBase,testParseWithInclude,#,115
Before Change
public void testParseWithInclude() throws Exception {
String testContent = "<profile name=\"test\"><include profile=\"foo\"/>" + MockAnyElement.getFullXmlContent() + "</profile>";
String fullcontent = MockRootElement.getXmlContent(getTargetNamespace(), getTargetNamespaceLocation(), true, testContent);
MockRootElement root = MockRootElementParser.parseRootElement(getXMLMapper(), new StringReader(fullcontent));
ProfileElement testee = (ProfileElement) root.getChild(getTargetNamespace(), Element.PROFILE.getLocalName());
assertEquals("test", testee.getName());
Set<ProfileIncludeElement> includes = testee.getIncludedProfiles();
assertEquals(1, includes.size());
After Change
public void testParseWithInclude() throws Exception {
String testContent = "<profile name=\"foo\">" + MockSubsystemElement.getAnotherSubsystemXmlContent() + "</profile>";
testContent += "<profile name=\"test\"><include profile=\"foo\"/>" + MockSubsystemElement.getSingleSubsystemXmlContent() + "</profile>";
testContent = ModelParsingSupport.wrap(Element.PROFILES.getLocalName(), testContent);
String fullcontent = ModelParsingSupport.getXmlContent(Element.DOMAIN.getLocalName(), getTargetNamespace(), getTargetNamespaceLocation(), testContent);
DomainModel root = ModelParsingSupport.parseDomainModel(getXMLMapper(), fullcontent);
ProfileElement testee = root.getProfile("test");
assertNotNull(testee);
assertEquals("test", testee.getName());
Set<String> includes = testee.getIncludedProfiles();